<?php
/* OpenBIBLIO -- A library administration web interface
 * Copyright (C) 2002-2005 Fr&eacute;d&eacute;ric Descamps <lefred@tiscali.be>
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 */

$eleve_id = $_GET['eleve_id'];

include_once("includes/functions.inc");
include_once("includes/db.inc");
$requete = "SELECT * FROM eleves where id=$eleve_id"; 
if(!($resultat = biblio_db_query($requete)))
{ print "PROBLEME : " .biblio_db_error(); }
else 
{
	while ($row = biblio_db_fetch_array($resultat)) 
	{      
	        $code = $row['code'];           
		$nom =  $row['nom'];                                
		$prenom =  $row['prenom'];                                		
		put_log(6,_("PRINT CARTE"). " : $prenom $nom",$user); 
	}
}    

?>
<HTML>
<head>
<style type="text/css" media="screen">
body {
        font-size: 0.9em;
        font-family: bitstream vera sans,sans-serif;
        margin: 10;
        padding: 10;
        /* (The background color is specified elsewhere, so do a global replacement if it ever changes) */
        background-color: #ffffff;
        color:  #cw3d3d3d;
}
#small {
   	font-size: 0.6em;
       	font-family: bitstream vera sans,sans-serif;
	   
}
#cadre1  {
	border: 2px solid #000000;
	padding: 0px 0px 0px 8px;
}
#cadre2 {
	border: 1px dashed #000000;
	padding: 8px 8px 8px 8px;
}
#cadre3  {
	border: 1px solid #000000;
	width: 1px;
}

</style>
</head>
<BODY>
<TABLE id=cadre1>
<TR><TD width=270>
<?php
$photo_path=get_picspath();
echo "<table id=cadre2>";
echo "<tr><td>";
echo "<span id=#message>$prenom<br><B>$nom</B></span>";
echo "</td><td>";
echo "<img src=images/photos/$code.jpg width=80>";
echo "</td></tr><tr><td>&nbsp;</td></tr><tr><td colspan=2>";
echo "<img src='barcode/image.php?code=$code&style=196&type=C128A&width=250&height=100&xres=2&font=5'></td></tr></table>";
?>
<span id=small>OpenBIBLIO (c) 2005</span>
</TD><TD id=cadre3></TD>
<TD width=270><CENTER>
<H2>Carte de lecteur</H2>
<img src="images/livre.jpg" WIDTH=50%><BR>
<i><?php echo get_title(); ?></i>
</CENTER></TD>
</TABLE>
</BODY>
</HTML>
